package com.example.demo.Service;

import com.example.demo.Dao.Usermapper;
import com.example.demo.Model.Userinfo;
import com.example.demo.Model.VO.UserinfoVO;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;


@Service
public class Userservice {
    @Autowired
    private Usermapper usermapper;


    public int reg(Userinfo userinfo) {
        return usermapper.reg(userinfo);
    }

    public Userinfo GetUserByName(String username) {
        return usermapper.GetUserByName(username);
    }

    public UserinfoVO getUserById(int uid) {
        return usermapper.getUserById(uid);
    }
}
